package com.lin.subject.domain.service;

import com.lin.subject.commom.entity.PageResult;
import com.lin.subject.domain.entity.SubjectInfoBO;
import com.lin.subject.infra.basic.entity.SubjectInfoEs;

import java.util.List;

/*
 * @Author Lin
 * @Description 题目相关
 * @Date 2024/10/21
 */
public interface SubjectInfoDomainService {
    /**
     * 新增题目
     * @param subjectInfoBo
     */
    void add(SubjectInfoBO subjectInfoBo) throws Exception;

    /**
     * 题目分页查询
     * @param subjectInfoBO
     * @return
     */
    PageResult<SubjectInfoBO> getSubjectPage(SubjectInfoBO subjectInfoBO);

    /**
     * 查询题目详情
     * @param subjectInfoBO
     * @return
     */
    SubjectInfoBO querySubjectInfo(SubjectInfoBO subjectInfoBO);

    /**
     * 删除题目
     * @param id
     */
    void deleteSubject(Long id);

    /**
     * 分页、全文检索
     * @param subjectInfoBO
     * @return
     */
    PageResult<SubjectInfoEs> getSubjectPageBySearch(SubjectInfoBO subjectInfoBO);

    /**
     * 获取共享榜
     * @return
     */
    List<SubjectInfoBO> getContributeList();
}
